package com.whut.welcomepage.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentStatePagerAdapter;

import java.util.List;

/**
 * Created by Noone on 2016/9/3.
 * Today is today!
 */
public class MainFragPagerAdapter extends FragmentStatePagerAdapter {
    private List<Fragment>mList;
    public MainFragPagerAdapter(FragmentManager fm,List<Fragment>list) {
        super(fm);
        mList=list;
    }

    @Override
    public Fragment getItem(int position) {
        return mList.get(position);
    }

    @Override
    public int getCount() {
        return mList.size();
    }

}
